$(()=> {
    let $btn = $('input'),
      num = window.localStorage.getItem('num') || 0;

  $btn.val(`被按了 ${num} 次`);

  $btn.click(() => {
        window.localStorage.setItem('num', ++num);
            $btn.val(`被按了 ${num} 次`);
              
  })


});

